<?php

class JavascriptButton extends PageElement
{
	private $action;
	private $javascript;

	public function __construct()
	{
	}

	public function setJavaScript($javascript)
	{
		$this->javascript = $javascript;
	}

	public function getHTML()
	{
		$html = "<input type=\"button\" onClick=\"".$this->javascript."\" ".parent::getHTML().">".$this->text."</input>\n";
		return $html;
	}

}

?>
